<%--
    Document   : User
    Created on : Oct 25, 2009, 10:09:20 PM
    Author     : Phong
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
<%@page import="java.sql.*" %>
<%@page import="java.util.Calendar" %>
<jsp:useBean id="mem" class="DAO.Result" scope="request" />
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

        <link rel="stylesheet" href="css/style.css" />
        <link rel="stylesheet" href="css/front.css"  />
        <link rel="styleshett" href="css/admin.css" type="text/css" media="screen" />
        <title>Themes</title>
    </head>
    <body bgcolor="#154978">
      
        <table width="1024" border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" align="center">
            <!--DWLayoutTable-->
            <tr>
                <td width="1024" height="157" valign="top" background="images/Banner.jpg">

                </td>
            </tr>
            <tr>
                <td height="463" valign="top">
                    <table width="100%" border="0" cellpadding="2" cellspacing="2">
                        <!--DWLayoutTable-->
                        <tr>
                            <td height="39" colspan="2" valign="top" background="images/button/bg_login.gif">
                            <%@include file="include/loginBar.jsp" %>	     </td>
                        </tr>
                        <tr>
                            <td width="179" height="537" valign="top">
                                <ul>
                                    <li><a href="InformationUser.jsp" style="">Thông tin tài khoản</a></li>
                                    <li><a href="Test.jsp">Kiểm Tra</a></li>
                                </ul></td>
                            <td width="831" align="center" valign="top" bgcolor="#CCCCCC">
                                <br>
                                <br>
                                <center style="color:red"><b>Thông tin tài khoản</b></center>
                                <br>
                                <br>
                                <br>
                                <%

            String username = request.getParameter("User");
            ResultSet rs2 = null;
            rs2 = mem.selectMember(username);
            while (rs2.next()) {
            String birthday = rs2.getString("Birthday");
                String str = birthday.substring(0,10);
                String year = str.substring(0, 4);
                String month = str.substring(5,7);
                String day = str.substring(8,10);
                String Birthday = day +"-"+month +"-" + year;
                                %>
                                <table border="1" class="sample" >
                                    <tbody>
                                        <tr>
                                            <td align="left">UserName :</td>
                                            <td align="left"><%=rs2.getString("UserName")%></td>
                                        </tr>
                                        <tr>
                                            <td align="left">Tên :</td>
                                            <td align="left"><%=rs2.getString("FullName")%></td>
                                        </tr>
                                        <tr>
                                            <td align="left">Sex :</td>
                                            <td align="left">
                                                <%
                if (rs2.getInt("Sex") == 1) {
                                                %>Male
                                                <%                                            } else {
                                                %>
                                                Female
                                                <%                }
                                                %>
                                            </td>
                                        </tr>

                                        <tr>
                                            <td align="left">Address</td>
                                            <td align="left"><%=rs2.getString("Address")%></td>
                                        </tr>
                                        <tr>
                                            <td align="left">Email :</td>
                                            <td align="left"> <%=rs2.getString("Email")%></td>
                                        </tr>
                                        <tr>
                                            <td align="left">Telephone :</td>
                                            <td align="left"><%=rs2.getString("Telephone")%></td>
                                        </tr>
                                        <tr>
                                            <td align="left">Birthday :</td>
                                            <td align="left"><%=Birthday%></td>
                                        </tr>
                                    </tbody>
                                </table>

                                <%
            }
                                %>


                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
        </table>



    </body>
</html>
